#!/bin/bash

# loop until the VM starts responding to pings
while ! $(relx_nodetool "ping">/dev/null)
do
    sleep 1
done

# loop until the name provided as argument gets
# registered
while true
do
    if [ "$(relx_nodetool eval "whereis($1).")" != "undefined" ]
    then
        break
    fi
done
